package com.xs.ai.services;

import org.springframework.ai.chat.client.AdvisedRequest;
import org.springframework.ai.chat.client.RequestResponseAdvisor;

import java.util.Map;


//日志记录step 1
public class LoggingAdvisor implements RequestResponseAdvisor {
    @Override
    public AdvisedRequest adviseRequest(AdvisedRequest request, Map<String, Object> context) {
        System.out.printf("Advising request: %s\n", request);
        return RequestResponseAdvisor.super.adviseRequest(request, context);
    }
}
